home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 11 / Cream of the Crop 11-1.iso / math / ast51src.zip / CHARTS0.C < prev    next >
C/C++ Source or Header  |  1995-12-31  |  46KB  |  1,177 lines

  1. /*
  2. ** Astrolog (Version 5.10) File: charts0.c
  3. **
  4. ** IMPORTANT NOTICE: The graphics database and chart display routines
  5. ** used in this program are Copyright (C) 1991-1995 by Walter D. Pullen
  6. ** (Astara@msn.com). Permission is granted to freely use and
  7. ** distribute these routines provided one doesn't sell, restrict, or
  8. ** profit from them in any way. Modification is allowed provided these
  9. ** notices remain with any altered or edited versions of the program.
  10. **
  11. ** The main planetary calculation routines used in this program have
  12. ** been Copyrighted and the core of this program is basically a
  13. ** conversion to C of the routines created by James Neely as listed in
  14. ** Michael Erlewine's 'Manual of Computer Programming for Astrologers',
  15. ** available from Matrix Software. The copyright gives us permission to
  16. ** use the routines for personal use but not to sell them or profit from
  17. ** them in any way.
  18. **
  19. ** The PostScript code within the core graphics routines are programmed
  20. ** and Copyright (C) 1992-1993 by Brian D. Willoughby
  21. ** (brianw@sounds.wa.com). Conditions are identical to those above.
  22. **
  23. ** The extended accurate ephemeris databases and formulas are from the
  24. ** calculation routines in the program "Placalc" and are programmed and
  25. ** Copyright (C) 1989,1991,1993 by Astrodienst AG and Alois Treindl
  26. ** (alois@azur.ch). The use of that source code is subject to
  27. ** regulations made by Astrodienst Zurich, and the code is not in the
  28. ** public domain. This copyright notice must not be changed or removed
  29. ** by any user of this program.
  30. **
  31. ** Initial programming 8/28,30, 9/10,13,16,20,23, 10/3,6,7, 11/7,10,21/1991.
  32. ** X Window graphics initially programmed 10/23-29/1991.
  33. ** PostScript graphics initially programmed 11/29-30/1992.
  34. ** Last code change made 12/27/1995.
  35. */
  36.  
  37. #include "astrolog.h"
  38.  
  39.  
  40. /*
  41. ******************************************************************************
  42. ** Table Display Routines.
  43. ******************************************************************************
  44. */
  45.  
  46. /* A subprocedure of the credit displayed below, this prints out one line */
  47. /* of credit information on the screen. Given a string, it's displayed    */
  48. /* centered with left and right borders around it, in the given color.    */
  49.  
  50. void PrintW(sz, col)
  51. char *sz;
  52. int col;
  53. {
  54.   int i;
  55.  
  56.   if (!sz) {
  57.  
  58.     /* Null string means print the top, bottom, or a separator row. */
  59.  
  60.     if (col < 0)
  61.       AnsiColor(kRed);
  62.     PrintCh((char)(col ? (col > 0 ? chSW : chNW) : chJE));
  63.     PrintTab(chH, CREDITWIDTH);
  64.     PrintCh((char)(col ? (col > 0 ? chSE : chNE) : chJW));
  65.   } else {
  66.     i = CchSz(sz);
  67.     PrintCh(chV);
  68.     PrintTab(' ', (CREDITWIDTH-i)/2 + (i&1));
  69.     AnsiColor(col);
  70.     PrintSz(sz);
  71.     PrintTab(' ', (CREDITWIDTH-i)/2);
  72.     AnsiColor(kRed);
  73.     PrintCh(chV);
  74.   }
  75.   PrintL();
  76. }
  77.  
  78.  
  79. /* Display a list of credits showing those who helped create the various  */
  80. /* parts of Astrolog, as well as important copyright and version info, as */
  81. /* displayed with the -Hc switch.                                         */
  82.  
  83. void DisplayCredits()
  84. {
  85.   char sz[cchSzDef];
  86.  
  87.   PrintW(NULL, -1);
  88.   sprintf(sz, "** %s version %s **", szAppName, szVersionCore);
  89.   PrintW(sz, kWhite);
  90.   sprintf(sz, "As of %s", szDateCore); PrintW(sz, kLtGray);
  91.   sprintf(sz, "By Walter D. Pullen (%s).", szAddressCore); PrintW(sz, kCyan);
  92.   PrintW(NULL, 0);
  93.   PrintW("Main planetary calculation formulas were converted from", kGreen);
  94.   PrintW(
  95.     "routines by James Neely, as listed in 'Manual of Computer Programming",
  96.     kGreen);
  97.   PrintW(
  98.     "for Astrologers' by Michael Erlewine, available from Matrix Software.",
  99.     kGreen);
  100.   PrintW("PostScript graphics routines by Brian D. Willoughby.", kYellow);
  101.   PrintW(
  102.     "Extended ephemeris calculation and formulas are by Alois Treindl,",
  103.     kMagenta);
  104.   PrintW(
  105.     "as in the package 'Placalc', available from Astrodienst AG.", kMagenta);
  106.   PrintW(
  107.     "IMPORTANT: Astrolog is 'freeware', but is copyrighted and not in public",
  108.     kLtGray);
  109.   PrintW(
  110.     "domain. Permission is granted to freely use and distribute these",
  111.     kLtGray);
  112.   PrintW(
  113.     "routines provided one does not sell, restrict, or profit from the",
  114.     kLtGray);
  115.   PrintW(
  116.     "program or its output in any way. Modification is allowed provided",
  117.     kLtGray);
  118.   PrintW(
  119.     "these exact notices remain with any altered or edited versions of the",
  120.     kLtGray);
  121.   PrintW(
  122.     "program. These conditions are true of both the program in whole and of",
  123.     kLtGray);
  124.   PrintW(
  125.     "all parts by any individual author. Violators are subject to copyright",
  126.     kLtGray);
  127.   PrintW(
  128.     "law penalties, and negative karmic debts to aforementioned contributors.",
  129.     kLtGray);
  130.   PrintW(NULL, 0);
  131.   PrintW(
  132.     "Special thanks to all those unmentioned, seen and unseen, who have",
  133.      kBlue);
  134.   PrintW(
  135.     "pointed out problems, suggested features, & sent many positive vibes! :)",
  136.     kBlue);
  137.   PrintW(NULL, 1);
  138.   AnsiColor(kDefault);
  139. }
  140.  
  141.  
  142. /* Print out a command switch or keypress info line to the screen, as done  */
  143. /* with the -H switch or 'H' key in a graphic window. This is just printing */
  144. /* out the string, except in Ansi mode we set the proper colors: Red for    */
  145. /* header lines, Green for individual switches or keys, and White for the   */
  146. /* rest of the line telling what it does. We also prefix each switch with   */
  147. /* either Unix's '-' or PC's '/', whichever is appropriate for the system.  */
  148.  
  149. void PrintS(sz)
  150. char *sz;
  151. {
  152.   int dash;
  153.   char c;
  154.  
  155.   dash = sz[1];
  156.   if (*sz != ' ')
  157.     AnsiColor(kRed);
  158.   else if (dash != ' ')
  159.     AnsiColor(dash == 'P' || sz[3] == ' ' || sz[3] == ':' ?
  160.       kGreen : kDkGreen);
  161.   else
  162.     AnsiColor(kDefault);
  163.   while ((c = *sz) && c != ':' &&
  164.     (dash != 'P' || (c != ' ' || *(sz+1) != 't'))) {
  165.     if (c != '_')
  166.       PrintCh(c);
  167.     else
  168.       PrintCh(chSwitch);
  169.     sz++;
  170.   }
  171.   if (*sz)
  172.     PrintCh(*sz++);
  173.   AnsiColor(kDefault);
  174.   while (c = *sz) {
  175.     if (c != '_')
  176.       PrintCh(c);
  177.     else
  178.       PrintCh(chSwitch);
  179.     sz++;
  180.   }
  181.   PrintL();
  182. }
  183.  
  184.  
  185. /* Print a list of every command switch that can be passed to the program, */
  186. /* and a description of what it does. This is what the -H switch prints.   */
  187.  
  188. void DisplaySwitches()
  189. {
  190.   char sz[cchSzDef];
  191.  
  192.   sprintf(sz, "%s (version %s) command switches:", szAppName, szVersionCore);
  193.   PrintS(sz);
  194.   PrintS(" _H: Display this help list.");
  195.   PrintS(" _Hc: Display program credits and copyrights.");
  196.   PrintS(" _HC: Display names of zodiac signs and houses.");
  197.   PrintS(" _HO: Display available planets and other celestial objects.");
  198.   PrintS(" _HA: Display available aspects, their angles, and present orbs.");
  199. #ifdef CONSTEL
  200.   PrintS(" _HF: Display names of astronomical constellations.");
  201. #endif
  202.   PrintS(" _HS: Display information about planets in the solar system.");
  203. #ifdef INTERPRET
  204.   PrintS(" _HI: Display meanings of signs, houses, planets, and aspects.");
  205. #endif
  206.   sprintf(sz,
  207.     " _He: Display all info tables together (_Hc_H_Y_HX_HC_HO_HA%s_HS%s).",
  208. #ifdef CONSTEL
  209.   "_HF",
  210. #else
  211.   "",
  212. #endif
  213. #ifdef INTERPRET
  214.   "_HI");
  215. #else
  216.   "");
  217. #endif
  218.   PrintS(sz);
  219.   PrintS(" _Q: Prompt for more command switches after display finished.");
  220. #ifdef SWITCHES
  221.   PrintS(" _Q0: Like _Q but prompt for additional switches on startup.");
  222. #endif
  223.   PrintS(" _M <1-48>: Run the specified command switch macro.");
  224.   PrintS(" _M0 <1-48> <string>: Define the specified command switch macro.");
  225.   PrintS(" _Y: Display help list of less commonly used command switches.");
  226.   PrintS("\nSwitches which determine the type of chart to display:");
  227.   PrintS(" _v: Display list of object positions (chosen by default).");
  228.   PrintS(" _v0: Like _v but express velocities relative to average speed.");
  229.   PrintS(" _w [<rows>]: Display chart in a graphic house wheel format.");
  230.   PrintS(" _w0 [..]: Like _w but reverse order of objects in houses 4..9.");
  231.   PrintS(" _g: Display aspect and midpoint grid among planets.");
  232.   PrintS(" _g0: Like _g but flag aspect configurations (e.g. Yod's) too.");
  233.   PrintS(" _g0: For comparison charts, show midpoints instead of aspects.");
  234.   PrintS(" _ga: Like _g but indicate applying instead of difference orbs.");
  235.   PrintS(" _gp: Like _g but generate parallel and contraparallel aspects.");
  236.   PrintS(" _a: Display list of all aspects ordered by influence.");
  237.   PrintS(" _a0: Like _a but display aspect summary too.");
  238.   PrintS(" _a[0]a: Like _a but indicate applying and separating orbs.");
  239.   PrintS(" _a[0]p: Like _a but do parallel and contraparallel aspects.");
  240.   PrintS(" _m: Display all object midpoints in sorted zodiac order.");
  241.   PrintS(" _m0: Like _m but display midpoint summary too.");
  242.   PrintS(" _ma: Like _m but show aspects from midpoints to planets as well.");
  243.   PrintS(" _Z: Display planet locations with respect to the local horizon.");
  244. #ifdef GRAPH
  245.   PrintS(" _Z0: Like _Z but express coordinates relative to polar center.");
  246. #endif
  247.   PrintS(" _Zd: Search day for object local rising and setting times.");
  248.   PrintS(" _S: Display x,y,z coordinate positions of planets in space.");
  249.   PrintS(" _j: Display astrological influences of each object in chart.");
  250.   PrintS(" _j0: Like _j but include influences of each zodiac sign as well.");
  251.   PrintS(" _L [<step>]: Display astro-graph locations of planetary angles.");
  252.   PrintS(" _L0 [..]: Like _L but display list of latitude crossings too.");
  253.   PrintS(" _K: Display a calendar for given month.");
  254.   PrintS(" _Ky: Like _K but display a calendar for the entire year.");
  255.   PrintS(" _d [<step>]: Print all aspects and changes occurring in a day.");
  256.   PrintS(" _dm: Like _d but print all aspects for the entire month.");
  257.   PrintS(" _dy: Like _d but print all aspects for the entire year.");
  258.   PrintS(" _dY <years>: Like _d but search within a number of years.");
  259.   PrintS(" _dp <month> <year>: Print aspects within progressed chart.");
  260.   PrintS(" _dpy <year>: Like _dp but search for aspects within entire year.");
  261.   PrintS(" _dpY <year> <years>: Like _dp but search within number of years.");
  262.   PrintS(" _dp[y]n: Search for progressed aspects in current month/year.");
  263.   PrintS(" _D: Like _d but display aspects by influence instead of time.");
  264.   PrintS(" _E: Display planetary ephemeris for given month.");
  265.   PrintS(" _Ey: Display planetary ephemeris for the entire year.");
  266.   PrintS(" _EY <years>: Display planetary ephemeris for a number of years.");
  267.   PrintS(
  268.     " _e: Print all charts together (i.e. _v_w_g0_a_m_Z_S_j0_L0_K_d_D_E).");
  269.   PrintS(
  270.     " _t <month> <year>: Compute all transits to natal planets in month.");
  271.   PrintS(
  272.     " _tp <month> <year>: Compute progressions in month for chart.");
  273.   PrintS(" _t[p]y: <year>: Compute transits/progressions for entire year.");
  274.   PrintS(" _t[p]Y: <year> <years>: Compute transits for a number of years.");
  275. #ifdef TIME
  276.   PrintS(" _t[py]n: Compute transits to natal planets for current time now.");
  277. #endif
  278.   PrintS(" _T <month> <day> <year>: Display transits ordered by influence.");
  279.   PrintS(" _Tp <month> <day> <year>: Print progressions instead of transits.");
  280. #ifdef TIME
  281.   PrintS(" _T[p]n: Display transits ordered by influence for current date.");
  282. #endif
  283. #ifdef ARABIC
  284.   PrintS(" _P [<parts>]: Display list of Arabic parts and their positions.");
  285.   PrintS(" _P0 [<parts>]: Like _P but display formulas with terms reversed.");
  286.   PrintS(" _P[z,n,f]: Order parts by position, name, or formula.");
  287. #endif
  288. #ifdef INTERPRET
  289.   PrintS(" _I [<columns>]: Print interpretation of selected charts.");
  290. #endif
  291.   PrintS("\nSwitches which affect how the chart parameters are obtained:");
  292. #ifdef TIME
  293.   PrintS(" _n: Compute chart for this exact moment using current time.");
  294.   PrintS(" _n[d,m,y]: Compute chart for start of current day, month, year.");
  295. #endif
  296.   PrintS(" _z [<zone>]: Change the default time zone (for _d_E_t_q options).");
  297.   PrintS(" _z0 [<offset>]: Change the default daylight time setting.");
  298.   PrintS(" _zl <long> <lat>: Change the default longitude & latitude.");
  299.   PrintS(" _zt <time>: Set only the time of current chart.");
  300.   PrintS(" _zd <date>: Set only the day of current chart.");
  301.   PrintS(" _zi <name> <place>: Set name and place strings of current chart.");
  302.   PrintS(" _q <month> <date> <year> <time>: Compute chart with defaults.");
  303.   PrintS(" _qd <month> <date> <year>: Compute chart for noon on date.");
  304.   PrintS(" _qm <month> <year>: Compute chart for first of month.");
  305.   PrintS(" _qy <year>: Compute chart for first day of year.");
  306.   PrintS(" _qa <month> <date> <year> <time> <zone> <long> <lat>:");
  307.   PrintS("     Compute chart automatically given specified data.");
  308.   PrintS(" _qb <month> <date> <year> <time> <daylight> <zone> <long> <lat>:");
  309.   PrintS("     Like _qa but takes additional parameter for daylight offset.");
  310.   PrintS(" _qj <day>: Compute chart for time of specified Julian day.");
  311.   PrintS(" _i <file>: Compute chart based on info in file.");
  312.   PrintS(" _o <file> [..]: Write parameters of current chart to file.");
  313.   PrintS(" _o0 <file> [..]: Like _o but output planet/house positions.");
  314.   PrintS(" _os <file>, > <file>: Redirect output of text charts to file.");
  315.   PrintS("\nSwitches which affect what information is used in a chart:");
  316.   PrintS(" _R [<obj1> [<obj2> ..]]: Restrict specific bodies from displays.");
  317.   PrintS(" _R0 [<obj1> ..]: Like _R but restrict everything first.");
  318.   PrintS(" _R1 [<obj1> ..]: Like _R0 but unrestrict and show all objects.");
  319.   PrintS(" _R[C,u,U]: Restrict all minor cusps, all uranians, or stars.");
  320.   PrintS(" _RT[0,1,C,u,U] [..]: Restrict transiting planets in _t lists.");
  321.   PrintS(" _RA [<asp1> ..]: Restrict aspects by giving them negative orbs.");
  322.   PrintS(" _C: Include angular and non-angular house cusps in charts.");
  323.   PrintS(" _u: Include transneptunian/uranian bodies in charts.");
  324.   PrintS(" _U: Include locations of fixed background stars in charts.");
  325.   PrintS(" _U[z,l,n,b]: Order by azimuth, altitude, name, or brightness.");
  326.   PrintS(" _A <0-18>: Specify the number of aspects to use in charts.");
  327.   PrintS(" _Ao <aspect> <orb>: Specify maximum orb for an aspect.");
  328.   PrintS(" _Am <planet> <orb>: Specify maximum orb allowed to a planet.");
  329.   PrintS(" _Ad <planet> <orb>: Specify orb addition given to a planet.");
  330.   PrintS(" _Aa <aspect> <angle>: Change the actual angle of an aspect.");
  331.   PrintS("\nSwitches which affect how a chart is computed:");
  332. #ifdef PLACALC
  333.   PrintS(" _b: Use ephemeris files for more accurate location computations.");
  334.   PrintS(" _b0: Like _b but display locations to the nearest second too.");
  335. #endif
  336.   PrintS(" _c <value>: Select a different default system of houses.");
  337.   PrintS("     (0 = Placidus, 1 = Koch, 2 = Equal, 3 = Campanus,");
  338.   PrintS("     4 = Meridian, 5 = Regiomontanus, 6 = Porphyry, 7 = Morinus,");
  339.   PrintS("     8 = Topocentric, 9 = Alcabitius, 10 = Equal (MC),");
  340.   PrintS("     11 = Neo-Porphyry, 12 = Whole, 13 = None.)");
  341.   PrintS(" _s [..]: Compute a sidereal instead of the normal tropical chart.");
  342.   PrintS(" _sr: Compute right ascension locations relative to equator.");
  343.   PrintS(
  344.     " _s[z,h,d]: Display locations as in zodiac, hours/minutes, or degrees.");
  345.   PrintS(" _h [<objnum>]: Compute positions centered on specified object.");
  346.   PrintS(" _p <month> <day> <year>: Cast 2ndary progressed chart for date.");
  347.   PrintS(" _p0 <month> <day> <year>: Cast solar arc chart for date.");
  348. #ifdef TIME
  349.   PrintS(" _p[0]n: Cast progressed chart based on current date now.");
  350. #endif
  351.   PrintS(" _pd <days>: Set no. of days to progress / day (default 365.25).");
  352.   PrintS(" _x <value>: Cast harmonic chart based on specified factor.");
  353.   PrintS(" _1 [<objnum>]: Cast chart with specified object on Ascendant.");
  354.   PrintS(" _2 [<objnum>]: Cast chart with specified object on Midheaven.");
  355.   PrintS(" _3: Display objects in their zodiac decan positions.");
  356.   PrintS(" _f: Display houses as sign positions (flip them).");
  357.   PrintS(" _G: Compute houses based on geographic location only.");
  358.   PrintS(" _F <objnum> <sign> <deg>: Force object's position to be value.");
  359.   PrintS(" _+ [<days>]: Cast chart for specified no. of days in the future.");
  360.   PrintS(" _- [<days>]: Cast chart for specified no. of days in the past.");
  361.   PrintS(" _+[m,y] [<value>]: Cast chart for no. of months/years in future.");
  362.   PrintS("\nSwitches for relationship and comparison charts:");
  363.   PrintS(" _r <file1> <file2>: Compute a relationship synastry chart.");
  364.   PrintS(" _rc <file1> <file2>: Compute a composite chart.");
  365.   PrintS(" _rm <file1> <file2>: Compute a time space midpoint chart.");
  366.   PrintS(" _r[c,m]0 <file1> <file2> <ratio1> <ratio2>: Weighted chart.");
  367.   PrintS(" _rd <file1> <file2>: Print time span between files' dates.");
  368. #ifdef BIORHYTHM
  369.   PrintS(" _rb <file1> <file2>: Display biorhythm for file1 at time file2.");
  370. #endif
  371.   PrintS(" _r0 <file1> <file2>: Keep the charts separate in comparison.");
  372.   PrintS(" _rp[0] <file1> <file2>: Like _r0 but do file1 progr. to file2.");
  373.   PrintS(" _rt <file1> <file2>: Like _r0 but treat file2 as transiting.");
  374. #ifdef TIME
  375.   PrintS(" _y <file>: Display current house transits for particular chart.");
  376. #ifdef BIORHYTHM
  377.   PrintS(" _y[b,d,p,t] <file>: Like _r0 but compare to current time now.");
  378. #endif
  379. #endif /* TIME */
  380.   PrintS("\nSwitches to access graphics options:");
  381.   PrintS(" _k: Display text charts using Ansi characters and color.");
  382. #ifdef MSG
  383.   PrintS(" _V: <25,43,50>: Start up with text mode set to number of rows.");
  384. #endif
  385.  
  386.   /* If graphics features are compiled in, call an additional procedure to */
  387.   /* display the command switches offered dealing with the graphics stuff. */
  388.  
  389. #ifdef GRAPH
  390.   DisplaySwitchesX();
  391. #ifdef WIN
  392.   DisplaySwitchesW();  /* Windows version has its own set of switches too. */
  393. #endif
  394. #endif /* GRAPH */
  395. }
  396.  
  397.  
  398. /* Print a list of the obscure command switches that can be passed to the */
  399. /* program and a description of them. This is what the -Y switch prints.  */
  400.  
  401. void DisplaySwitchesRare()
  402. {
  403.   char sz[cchSzDef];
  404.  
  405.   sprintf(sz, "%s (version %s) obscure command switches:",
  406.     szAppName, szVersionCore);
  407.   PrintS(sz);
  408.   PrintS(" _Y: Display this help list.");
  409.   PrintS(" _Yn: Compute location of true instead of mean node.");
  410.   PrintS(" _Yd: Display dates in D/M/Y instead of M/D/Y format.");
  411.   PrintS(" _Yt: Display times in 24 hour instead of am/pm format.");
  412.   PrintS(" _YC: Automatically ignore insignificant house cusp aspects.");
  413.   PrintS(" _Y8: Clip text charts at the rightmost (e.g. 80th) column.");
  414.   PrintS(" _YQ <rows>: Pause text scrolling after a page full has printed.");
  415.   PrintS(" _Yo: Output chart info and position files in old style format.");
  416.   PrintS(" _Yc: Angular cusp objects are house positions instead of angles.");
  417.   PrintS(" _Yz <min>: Forward clock by amount for current moment charts.");
  418. #ifdef ARABIC
  419.   PrintS(" _YP <-1,0,1>: Set how Arabic parts are computed for night charts.");
  420. #endif
  421.   PrintS(" _YE <obj> <semi-major axis> <eccentricity (3)> <inclination (3)>");
  422.   PrintS("     <perihelion (3)> <ascending node (3)> <time offset (3)>");
  423.   PrintS("     Change orbit of object to be the given elements.");
  424.   PrintS(
  425.     " _YR <obj1> <obj2> <flag1>..<flag2>: Set restrictions for object range.");
  426.   PrintS(
  427.     " _YRT <obj1> <obj2> <flag1>..<flag2>: Transit restrictions for range.");
  428.   PrintS(
  429.     " _YR0 <flag1> <flag2>: Set restrictions for sign, direction changes.");
  430.   PrintS(
  431.     " _YAo <asp1> <asp2> <orb1>..<orb2>: Set aspect orbs for range.");
  432.   PrintS(
  433.     " _YAm <obj1> <obj2> <orb1>..<orb2>: Set max planet orbs for range.");
  434.   PrintS(
  435.     " _YAd <obj1> <obj2> <orb1>..<orb2>: Set planet orb additions for range.");
  436.   PrintS(
  437.     " _YAa <asp1> <asp2> <ang1>..<ang2>: Set planet aspect angles for range.");
  438.   PrintS(
  439.     " _Yj <obj1> <obj2> <inf1>..<inf2>: Set influences for object range.");
  440.   PrintS(
  441.     " _YjC <cusp1> <cusp2> <inf1>..<inf2>: Set influences for house cusps.");
  442.   PrintS(
  443.     " _YjA <asp1> <asp2> <inf1>..<inf2>: Set influences for aspect range.");
  444.   PrintS(
  445.     " _YjT <obj1> <obj2> <inf1>..<inf2>: Set transit influences for range.");
  446.   PrintS(
  447.     " _Yj0 <inf1> <inf2> <inf3> <inf4>: Set influences given to planets");
  448.   PrintS("     in ruling sign, exalted sign, ruling house, exalted house.");
  449.   PrintS(" _YI <obj> <string>: Customize interpretation for object.");
  450.   PrintS(
  451.     " _YIa <sign> <string>: Customize interpretation adjective for sign.");
  452.   PrintS(" _YIv <sign> <string>: Customize interpretation verb for sign.");
  453.   PrintS(" _YIC <house> <string>: Customize interpretation for house.");
  454.   PrintS(" _YIA <asp> <string>: Customize interpretation for aspect.");
  455.   PrintS(" _YIA0 <asp> <string>: Customize aspect interpretation statement.");
  456.   PrintS(" _YkC <fir> <ear> <air> <wat>: Customize element colors.");
  457.   PrintS(" _YkA <asp1> <asp2> <col1>..<col2>: Customize aspect colors.");
  458.   PrintS(" _Yk0 <1..7> <1..7> <col1>..<col2>: Customize 'rainbow' colors.");
  459.   PrintS(" _Yk <0..8> <0..8> <col1>..<col2>: Customize 'general' colors.");
  460.   PrintS(" _YXG <0-2><0-2><0-2><0-3>: Select among different graphic glyphs");
  461.   PrintS("     for Capricorn, Uranus, Pluto, and Lilith.");
  462.   PrintS(" _YXg <cells>: Set number of cells for graphic aspect grid.");
  463.   PrintS(" _YXf <val>: Set usage of actual system fonts in graphic file.");
  464.   PrintS(" _YXp <-1,0,1>: Set paper orientation for PostScript files.");
  465.   PrintS(" _YXp0 <hor> <ver>: Set paper size for PostScript files.");
  466. #ifdef PCG
  467.   PrintS(" _YX <hi-res> <lo-res>: Set modes to use for PC screen graphics.");
  468. #endif
  469.   PrintS(" _0[o,i,q,X]: Disallow file output, input, exiting, and graphics.");
  470.   PrintS(" _;: Ignore rest of command line and treat it as a comment.");
  471. }
  472.  
  473.  
  474. /* Print out a list of the various objects - planets, asteroids, house     */
  475. /* cusps, stars - recognized by the program, and their index values. This  */
  476. /* is displayed when the -O switch is invoked. For some objects, display   */
  477. /* additional information, e.g. ruling signs for planets, brightnesses and */
  478. /* positions in the sky for fixed stars, etc.                              */
  479.  
  480. void PrintObjects()
  481. {
  482.   char sz[cchSzDef];
  483.   CI ci;
  484.   int i, j;
  485.   real Off;
  486.  
  487.   if (!us.fCusp)
  488.     for (i = cuspLo; i <= cuspHi; i++)    /* Set up restrictions properly: */
  489.       ignore[i] = fTrue;                  /* Minor cusps and uranians      */
  490.   if (!us.fUranian)                       /* included only if -C and -u    */
  491.     for (i = uranLo; i <= uranHi; i++)    /* switches are in effect.       */
  492.       ignore[i] = fTrue;
  493.   sprintf(sz, "%s planets and objects:\n", szAppName);
  494.   PrintSz(sz);
  495.   PrintSz("No. Name       Rule Co-Rule Fall Co-Fall Exalt Debilitate\n\n");
  496.   for (i = 1; i <= oNorm; i++) if (!ignore[i]) {
  497.     AnsiColor(kObjA[i]);
  498.     sprintf(sz, "%2d %-12s", i, szObjName[i]); PrintSz(sz);
  499.     if (i <= oCore) {                              /* Print rulerships, etc */
  500.       if (ruler1[i]) {                             /* for the planets.      */
  501.         j = ruler2[i];
  502.         sprintf(sz, "%c%c%c  %c%c%c     ", chSig3(ruler1[i]),
  503.           j ? szSignName[j][0] : ' ', j ? szSignName[j][1] : ' ',
  504.           j ? szSignName[j][2] : ' '); PrintSz(sz);
  505.         sprintf(sz, "%c%c%c  %c%c%c     ", chSig3(Mod12(ruler1[i]+6)),
  506.           j ? szSignName[Mod12(j+6)][0] : ' ',
  507.           j ? szSignName[Mod12(j+6)][1] : ' ',
  508.           j ? szSignName[Mod12(j+6)][2] : ' '); PrintSz(sz);
  509.         sprintf(sz, "%c%c%c   %c%c%c", chSig3(exalt[i]),
  510.           chSig3(Mod12(exalt[i]+6))); PrintSz(sz);
  511.       }
  512.     } else {
  513.       if (ruler1[i]) {
  514.         sprintf(sz, "%c%c%c          %c%c%c", chSig3(ruler1[i]),
  515.           chSig3(Mod12(ruler1[i]+6))); PrintSz(sz);
  516.         sprintf(sz, "          %c%c%c   %c%c%c", chSig3(exalt[i]),
  517.           chSig3(Mod12(exalt[i]+6))); PrintSz(sz);
  518.       }
  519.       if (i <= cuspHi)
  520.         sprintf(sz, "  House Cusp #%d", i-cuspLo+1);
  521.       else
  522.         sprintf(sz, "  Uranian #%d", i-uranLo+1);
  523.       PrintSz(sz);
  524.     }
  525.     PrintL();
  526.   }
  527.  
  528.   /* Now, if -U in effect, read in and display stars in specified order. */
  529.  
  530.   if (us.nStar) {
  531.     ci = ciCore;
  532.     Off = ProcessInput(fTrue);
  533.     ciCore = ci;
  534.     ComputeStars(us.fSidereal ? 0.0 : -Off);
  535.     for (i = starLo; i <= starHi; i++) if (!ignore[i]) {
  536.       j = oNorm+starname[i-oNorm];
  537.       AnsiColor(kObjA[j]);
  538.       sprintf(sz, "%2d %-12s", i, szObjName[j]); PrintSz(sz);
  539.       sprintf(sz, "Star #%2d   ", i-oNorm); PrintSz(sz);
  540.       PrintZodiac(planet[j]);
  541.       PrintTab(' ', 4);
  542.       PrintAltitude(planetalt[j]);
  543.       sprintf(sz, " %5.2f\n", rStarBright[j-oNorm]); PrintSz(sz);
  544.     }
  545.   }
  546.   AnsiColor(kDefault);
  547. }
  548.  
  549.  
  550. /* Print out a list of all the aspects recognized by the program, and info  */
  551. /* about them: their names, index numbers, degree angles, present orbs, and */
  552. /* the description of their glyph. This gets displayed when the -A switch   */
  553. /* is invoked (without any argument).                                       */
  554.  
  555. void PrintAspects()
  556. {
  557.   char sz[cchSzDef];
  558.   int i;
  559.  
  560.   sprintf(sz,
  561.     "%s aspects:\nNo. Name         Abbrev. ", szAppName); PrintSz(sz);
  562.   PrintSz("Angle    Orb          Description of glyph\n\n");
  563.   for (i = 1; i <= cAspect; i++) {
  564.     AnsiColor(kAspA[i]);
  565.     sprintf(sz, "%2d %-15s(%s) %6.2f +/- %1.0f degrees - %s\n",
  566.       i, szAspectName[i], szAspectAbbrev[i],
  567.       rAspAngle[i], rAspOrb[i], szAspectGlyph[i]); PrintSz(sz);
  568.   }
  569.   AnsiColor(kDefault);
  570. }
  571.  
  572.  
  573. /* Print out a list of the 12 signs and houses of the zodiac, and their    */
  574. /* standard and traditional names, as done when the -H0 switch is invoked. */
  575.  
  576. void PrintSigns()
  577. {
  578.   char sz[cchSzDef];
  579.   int i;
  580.  
  581.   sprintf(sz, "%s signs and houses:\n", szAppName); PrintSz(sz);
  582.   PrintSz("Sign        English name      House Traditional name\n\n");
  583.   for (i = 1; i <= cSign; i++) {
  584.     AnsiColor(kSignA(i));
  585.     sprintf(sz, "%-12sthe %-14s%2d%s  House of %s\n",
  586.       szSignName[i], szSignEnglish[i], i, szSuffix[i], szHouseTradition[i]);
  587.     PrintSz(sz);
  588.   }
  589.   AnsiColor(kDefault);
  590. }
  591.  
  592.  
  593. #ifdef CONSTEL
  594. /* Given the standard 'noun' form of a constellation string, convert it  */
  595. /* to its genitive or posessive form. Some standard rules are used but a */
  596. /* special instructions string is passed for special cases.              */
  597.  
  598. char *GetSzGenitive(szGen, szInst)
  599. char *szGen, *szInst;
  600. {
  601.   char *pch, ch1, ch2;
  602.   int cch;
  603.  
  604.   pch = szGen + CchSz(szGen);
  605.   if (*szInst == ' ')            /* Instructions starting with a space or */
  606.     szInst++;                    /* that are empty means no special case. */
  607.   else if (*szInst) {
  608.     cch = *szInst - '0';
  609.     if (cch < 10) {          /* Instructions starting with a number means */
  610.       szInst++;              /* hack off that many characters of string.  */
  611.       pch -= cch;
  612.     }
  613.     while (*szInst > '9')  /* Instructions end with characters to append. */
  614.       *pch++ = *szInst++;
  615.     *pch = chNull;
  616.     return szInst;
  617.   }
  618.   ch1 = *(pch-1);
  619.   ch2 = *(pch-2);
  620.   if (ch1 == 'a') {           /* Standard rule: 'a' ending -> 'ae'. */
  621.     *pch++ = 'e';
  622.     *pch = chNull;
  623.   } else if (ch1 == 's' && ch2 == 'u') {     /* 'us' ending -> 'i'. */
  624.     *(pch-2) = 'i';
  625.     *(pch-1) = chNull;
  626.   } else if (ch1 == 'm' && ch2 == 'u') {     /* 'um' ending -> 'i'. */
  627.     *(pch-2) = 'i';
  628.     *(pch-1) = chNull;
  629.   } else if (ch1 == 'x')     /* Standard rule: 'x' ending -> 'cis'. */
  630.     sprintf(pch-1, "cis");
  631.   return szInst;
  632. }
  633.  
  634.  
  635. /* Given a constellation index, fill out a string with the genitive or   */
  636. /* posessive form of its name. This basically just calls GetSzGenitive() */
  637. /* above, however it has to be called twice for names having two words.  */
  638.  
  639. void GetSzConstel(szGen, i)
  640. char *szGen;
  641. int i;
  642. {
  643.   char sz1[cchSzDef], sz2[cchSzDef], *pchSpace, *szInst;
  644.  
  645.   sprintf(szGen, "%s", szCnstlName[i]);
  646.   for (pchSpace = szGen; *pchSpace && *pchSpace != ' '; pchSpace++)
  647.     ;
  648.   szInst = (char *)szCnstlGenitive[i];
  649.   if (*pchSpace == chNull) {
  650.     GetSzGenitive(szGen, szInst);
  651.     return;
  652.   }
  653.   *pchSpace = chNull;
  654.   if (szInst[0] == '!') {
  655.     GetSzGenitive(szGen, szInst+1);
  656.     return;
  657.   }
  658.   sprintf(sz1, "%s", szGen);
  659.   sprintf(sz2, "%s", pchSpace+1);
  660.   szInst = GetSzGenitive(sz1, szInst);
  661.   GetSzGenitive(sz2, szInst);
  662.   sprintf(szGen, "%s %s", sz1, sz2);
  663. }
  664.  
  665.  
  666. /* Print out a list of the 88 constellations used in astronomy, in their  */
  667. /* standard, English, and genitive forms, as invoked with the -HF switch. */
  668.  
  669. void PrintConstellations()
  670. {
  671.   int i, j = eWat;
  672.   char szGen[cchSzDef], sz[cchSzDef], chLast = chNull;
  673.  
  674.   sprintf(sz, "%s constellations:\n", szAppName); PrintSz(sz);
  675.   PrintSz("No. Name                Abbrev.   ");
  676.   PrintSz("Meaning            Genitive form\n\n");
  677.   for (i = 1; i <= cCnstl; i++) {
  678.     if (szCnstlName[i][0] != chLast) {
  679.       chLast = szCnstlName[i][0];
  680.       j = j + 1 & 3;
  681.       AnsiColor(kElemA[j]);
  682.     }
  683.     sprintf(sz, "%2d: %-19s (%s) ", i, szCnstlName[i], szCnstlAbbrev[i]);
  684.     PrintSz(sz);
  685.     if (szCnstlMeaning[i][0] == ' ')
  686.       sprintf(sz, "%-22s", szCnstlMeaning[i]+1);
  687.     else
  688.       sprintf(sz, "the %-18s", szCnstlMeaning[i]);
  689.     PrintSz(sz);
  690.     GetSzConstel(szGen, i);
  691.     sprintf(sz, " (%s)\n", szGen); PrintSz(sz);
  692.   }
  693.   AnsiColor(kDefault);
  694. }
  695. #endif /* CONSTEL */
  696.  
  697.  
  698. /* Print out a list of the planets in the solar system (and our Moon), */
  699. /* listing astronomical info on them, as invoked with the -HS switch.  */
  700.  
  701. void PrintOrbit()
  702. {
  703.   char sz[cchSzDef];
  704.   int i;
  705.   real r;
  706.  
  707.   sprintf(sz, "%s planets:\n", szAppName); PrintSz(sz);
  708.   PrintSz("   Name: Distance   Year Diameter     Day       Mass Density  ");
  709.   PrintSz("Axis Satellites\n\n");
  710.   for (i = 0; i <= oVes; i++) {
  711.     AnsiColor(kObjA[i]);
  712.     sprintf(sz, "%7s:%9.3f%7.2f%9.3f", szObjName[i],
  713.       rObjDist[i]/rObjDist[0], rObjYear[i], rObjDiam[i]/rObjDiam[0]);
  714.     PrintSz(sz);
  715.     if (i <= oPlu) {
  716.       r = rObjDiam[i]*1000.0/2.0;
  717.       sprintf(sz, "%8.2f%11.3f%8.2f%6.2f%11d",
  718.         rObjDay[i], rObjMass[i],
  719.         (rObjMass[i]*5.974E24/1000.0)/((4.0/3.0)*(r*r*r)*rPi),
  720.         rObjAxis[i], cSatellite[i]);
  721.       PrintSz(sz);
  722.     }
  723.     PrintL();
  724.   }
  725.   AnsiColor(kDefault);
  726. }
  727.  
  728.  
  729. #ifdef ARABIC
  730. /* Compare the strings corresponding to two Arabic part formulas. Like   */
  731. /* NCompareSz, this returns 0 if they are equal, a positive value if the */
  732. /* first is greater, and negative if the second is greater.              */
  733.  
  734. int NCompareSzPart(ap1, ap2)
  735. int ap1, ap2;
  736. {
  737.   char *pch1, *pch2;
  738.   int ich;
  739.  
  740.   pch1 = ai[ap1].form; pch2 = ai[ap2].form;
  741.   for (ich = 0; pch1[ich] && pch1[ich] == pch2[ich]; ich++) {
  742.     if (!us.fArabicFlip) {
  743.  
  744.       /* If formulas are being displayed in alternate form, we need to */
  745.       /* effectively swap two sections in the string and then compare. */
  746.  
  747.       if (ich == 2)
  748.         ich = 5;
  749.       else if (ich == 8)
  750.         ich = 2;
  751.       else if (ich == 5)
  752.         ich = 8;
  753.     }
  754.   }
  755.   return pch1[ich] - pch2[ich];
  756. }
  757.  
  758.  
  759. /* Print out a list of all the Arabic parts in the current chart, computing */
  760. /* their positions first, as brought up with the -P switch.                 */
  761.  
  762. void DisplayArabic()
  763. {
  764.   real rPart[cPart], rBit[3], rCur;
  765.   char sz[cchSzDef], *pch, ch;
  766.   int iPart[cPart], h, i, j, k, l;
  767.  
  768.   PrintSz("Num."); PrintTab(' ', 20); PrintSz("Name Position");
  769.   PrintTab(' ', 1 + 4 * is.fSeconds);
  770.   PrintSz("House Formula              Flip Type\n");
  771.  
  772.   /* Calculate the zodiac positions of all the parts. */
  773.  
  774.   for (i = 0; i < cPart; i++) {
  775.     rPart[i] = -rDegMax;
  776.     if (i >= us.nArabicParts)
  777.       goto LNextPart;
  778.     for (j = 0; j < 3; j++) {
  779.       pch = &ai[i].form[j*3];
  780.       ch = pch[1];
  781.       if (ch == ' ')
  782.         k = oAsc;
  783.       else if (ch == 'F')
  784.         k = -apFor;
  785.       else if (ch == 'S')
  786.         k = -apSpi;
  787.       else
  788.         k = (ch-'0') * 10 + (pch[2]-'0');
  789.       ch = *pch;
  790.       if (ch == 'h')      /* House cusp */
  791.         rCur = house[k];
  792.       else if (ch == 'r') /* Ruler of house cusp */
  793.         rCur = planet[rules[SFromZ(house[k])]];
  794.       else if (ch == 'j') /* 10 degrees of house cusp */
  795.         rCur = house[k] + 10.0;
  796.       else if (ch == 'H') /* Planet's house */
  797.         rCur = house[inhouse[k]];
  798.       else if (ch == 'R') /* Ruler of planet's house */
  799.         rCur = planet[rules[SFromZ(house[inhouse[k]])]];
  800.       else if (ch == 'D') /* Dispositor / ruler of planet's position */
  801.         rCur = planet[rules[SFromZ(planet[k])]];
  802.       else if (FBetween(ch, '0', '3'))
  803.         rCur = (real)((ch-'0') * 100 + k);
  804.       else {
  805.         if (k < 1) {
  806.           rCur = rPart[-k];
  807.           if (rCur < 0.0)
  808.             goto LNextPart;
  809.         } else {
  810.           if (ignore[k] && (us.fCusp || !FCusp(k)))
  811.             goto LNextPart;
  812.           else
  813.             rCur = planet[k];
  814.         }
  815.       }
  816.       rBit[j] = rCur;
  817.     }
  818.     rCur = rBit[1] - rBit[2];
  819.     if (us.nArabicNight < 0 || (ai[i].form[9] == 'F' &&
  820.       inhouse[oSun] < sLib && us.nArabicNight == 0))
  821.       rCur = -rCur;
  822.     rCur = Mod(rCur + rBit[0]);
  823.     rPart[i] = rCur;
  824. LNextPart:
  825.     iPart[i] = i;
  826.   }
  827.  
  828.   /* Sort parts to figure out what order to display them in. */
  829.  
  830.   if (us.nArabic > 1) for (i = 1; i < cPart; i++) {
  831.     j = i-1;
  832.  
  833.     /* Compare part zodiac locations for -Pz switch. */
  834.  
  835.     if (us.nArabic == 'z') while (j >= 0 &&
  836.       rPart[iPart[j]] > rPart[iPart[j+1]]) {
  837.       SwapN(iPart[j], iPart[j+1]);
  838.       j--;
  839.  
  840.     /* Compare part names for -Pn switch. */
  841.  
  842.     } else if (us.nArabic == 'n') while (j >= 0 && NCompareSz(
  843.       ai[iPart[j]].name, ai[iPart[j+1]].name) > 0) {
  844.       SwapN(iPart[j], iPart[j+1]);
  845.       j--;
  846.  
  847.     /* Compare part formulas for -Pf switch. */
  848.  
  849.     } else if (us.nArabic == 'f') while (j >= 0 && NCompareSzPart(
  850.       iPart[j], iPart[j+1]) > 0) {
  851.       SwapN(iPart[j], iPart[j+1]);
  852.       j--;
  853.     }
  854.   }
  855.  
  856.   /* Display the positions and formulas of the parts. */
  857.  
  858.   for (h = i = 0; i < cPart; i++) {
  859.     l = iPart[i];
  860.     if (rPart[l] < 0.0)
  861.       continue;
  862.     sprintf(sz, "%3d: %23.23s ", ++h, ai[l].name); PrintSz(sz);
  863.     PrintZodiac(rPart[l]);
  864.     j = HousePlaceIn(rPart[l]);
  865.     sprintf(sz, " [%2d%s] ", j, szSuffix[j]);
  866.     AnsiColor(kSignA(j)); PrintSz(sz); AnsiColor(kDefault);
  867.     PrintCh('(');
  868.     for (j = 0; j < 3; j++) {
  869.       k = j < 1 || us.fArabicFlip ? j : 3-j;
  870.       pch = &ai[l].form[k*3];
  871.       ch = pch[1];
  872.       if (ch == ' ')
  873.         k = oAsc;
  874.       else if (ch == 'F')
  875.         k = -apFor;
  876.       else if (ch == 'S')
  877.         k = -apSpi;
  878.       else
  879.         k = (ch-'0') * 10 + (pch[2]-'0');
  880.       ch = *pch;
  881.       if (k < 1) {
  882.         AnsiColor(kObjA[oFor]);
  883.         sprintf(sz, "%3.3s", ai[-k].name); PrintSz(sz);
  884.       } else {
  885.         if (ch == ' ' || ch == 'H' || ch == 'R' || ch == 'D') {
  886.           AnsiColor(kSignA(ruler1[k]));
  887.           sprintf(sz, "%c%c%c", chObj3(k));
  888.         } else if (FBetween(ch, '0', '3')) {
  889.           k = (ch-'0') * 100 + k;
  890.           AnsiColor(kSignA(k/30+1));
  891.           sprintf(sz, "%2d%c%c%c", k%30, chSig3(k/30+1));
  892.         } else {
  893.           AnsiColor(kSignA(k));
  894.           sprintf(sz, "%3d", k);
  895.         }
  896.         PrintSz(sz);
  897.       }
  898.       AnsiColor(kDefault);
  899.       if (sz[3] == chNull) {
  900.         PrintCh(' ');
  901.         switch (ch) {
  902.         case 'h': ch = ' '; break;
  903.         case 'r': ch = 'R'; break;
  904.         case 'j': ch = '&'; break;
  905.         default: ch = *pch;
  906.         }
  907.         PrintCh(ch);
  908.       }
  909.       if (j < 2) {
  910.         sprintf(sz, " %c ", (j < 1 == us.fArabicFlip) ? '+' : '-');
  911.         PrintSz(sz);
  912.       }
  913.     }
  914.     PrintCh(' ');
  915.     ch = ai[l].form[9];
  916.     switch (ch) {
  917.     case 'F': PrintSz("Y"); break;
  918.     default: AnsiColor(kWhite); PrintSz("N"); AnsiColor(kDefault); break;
  919.     }
  920.     PrintSz(") ");
  921.     ch = ai[l].form[10];
  922.     switch (ch) {
  923.     case 'C': AnsiColor(kElemA[eWat]); PrintSz("Comm."); break;
  924.     case 'E': AnsiColor(kElemA[eFir]); PrintSz("Event"); break;
  925.     case 'H': AnsiColor(kElemA[eEar]); PrintSz("Hora."); break;
  926.     }
  927.     AnsiColor(kDefault);
  928.     PrintL();
  929.   }
  930. }
  931. #endif /* ARABIC */
  932.  
  933.  
  934. #ifdef GRAPH
  935. /* Print a list of every key that one can press in a graphics window to do  */
  936. /* a certain function, and a description of what it does, as displayed when */
  937. /* one presses the 'H' or '?' key, and as shown with the -HX switch.        */
  938.  
  939. void DisplayKeysX()
  940. {
  941.   char sz[cchSzDef];
  942.  
  943.   sprintf(sz, "%s graphics screen key press options (version %s):",
  944.     szAppName, szVersionCore);
  945.   PrintS(sz);
  946.   PrintS(" Press 'H' or '?' to display this list of key options.");
  947.   PrintS(" Press 'p' to toggle pause status on or off.");
  948.   PrintS(" Press 'x' to toggle fg/bg colors on screen.");
  949.   PrintS(" Press 'm' to toggle color/monochrome display on screen.");
  950.   PrintS(" Press 'i' to toggle status of the minor chart modification.");
  951.   PrintS(" Press 't' to toggle header info on current chart on screen.");
  952.   PrintS(" Press 'b' to toggle drawing of a border around the chart.");
  953.   PrintS(" Press 'l' to toggle labeling of object points in chart.");
  954.   PrintS(" Press 'j' to toggle not clearing screen between chart updates.");
  955.   PrintS(" Press 'v' to display current chart positions on text screen.");
  956.   PrintS(" Press 'R', 'C', 'u', 'U' to toggle restriction status of minor");
  957.   PrintS("       objects, minor house cusps, uranian planets, and stars.");
  958.   PrintS(" Press 'c' to toggle relationship comparison chart mode.");
  959.   PrintS(" Press 's', 'h', 'f', 'g' to toggle status of sidereal zodiac,");
  960.   PrintS("       heliocentric charts, domal charts, and decan charts.");
  961.   PrintS(" Press 'O' and 'o' to recall/store a previous chart from memory.");
  962. #ifdef X11
  963.   PrintS(" Press 'B' to dump current window contents to root background.");
  964. #else
  965.   PrintS(" Press 'B' to resize chart display to full size of screen.");
  966. #endif
  967.   PrintS(" Press 'Q' to resize chart display to a square.");
  968.   PrintS(" Press '<' and '>' to decrease/increase the scale size of the");
  969.   PrintS("       glyphs and the size of world map.");
  970.   PrintS(" Press '[' and ']' to decrease/increase tilt in globe display.");
  971.   PrintS(" Press '+' and '-' to add/subtract a day from current chart.");
  972. #ifdef TIME
  973.   PrintS(" Press 'n' to set chart information to current time now.");
  974. #endif
  975.   PrintS(" Press 'N' to toggle animation status on or off. Charts will");
  976.   PrintS("       be updated to current status and globe will rotate.");
  977.   PrintS(" Press '!'-'(' to begin updating current chart by adding times.");
  978.   PrintS("       !: seconds, @: minutes, #: hours, $: days, %: months,");
  979.   PrintS("       ^: years, &: years*10, *: years*100, (: years*1000.");
  980.   PrintS(" Press 'r' to reverse direction of time-lapse or animation.");
  981.   PrintS(" Press '1'-'9' to set rate of animation to 'n' degrees, etc.");
  982. #ifdef PCG
  983.   PrintS(" Press '1'-'9' to determine section of chart to show if clipped.");
  984. #endif
  985.   PrintS(" Press 'V','L','A','Z','S','J','K','E','W','G','P' to switch to");
  986.   PrintS("       normal (_v), astro-graph (_L), grid (_g), local (_Z),");
  987.   PrintS("       space (_S), dispositor (_j), calendar (_K), ephemeris");
  988.   PrintS("       (_E), world map (_XW), globe (_XG), and polar (_XP) modes.");
  989.   PrintS(" Press 'Y' to switch to biorhythm relation chart mode.");
  990.   PrintS(" Press '0' to toggle between _Z,_Z0 & _XW,_XW0 & _E,_Ey modes.");
  991. #ifdef CONSTEL
  992.   PrintS(" Press 'F' to toggle between world and constellation map modes.");
  993. #endif
  994. #ifdef PCG
  995.   PrintS(" Press 'F1'..'F12' [plus Shift,Ctrl,Alt] to run macros 1..48.");
  996. #endif
  997.   PrintS(" Press 'space' to force redraw of current graphics display.");
  998.   PrintS(" Press 'del' to clear the graphics screen and not redraw.");
  999. #ifdef PCG
  1000.   PrintS(" Press 'tab' to toggle between graphics resolutions.");
  1001. #endif
  1002.   PrintS(" Press 'enter' to input a command line of general switches.");
  1003.   PrintS(" Press 'q' to terminate graphics and the program.");
  1004. #ifdef MOUSE
  1005.   PrintL();
  1006. #ifdef X11
  1007.   PrintS(" Left   mouse button: Draw line strokes on chart in window.");
  1008.   PrintS(" Middle mouse button: Print coordinates of pointer on world map.");
  1009.   PrintS(" Right  mouse button: Terminate the window and program.");
  1010. #endif
  1011. #ifdef PCG
  1012.   PrintS(" Left  mouse button: Draw line strokes on chart in screen.");
  1013.   PrintS(" Right mouse button: Set coordinates to pointer on world map.");
  1014. #endif
  1015. #endif /* MOUSE */
  1016. }
  1017.  
  1018.  
  1019. /* Print a list of every command switch dealing with the graphics features  */
  1020. /* that can be passed to the program, and a description of what it does.    */
  1021. /* This is part of what the -H switch prints, if graphics were compiled in. */
  1022.  
  1023. void DisplaySwitchesX()
  1024. {
  1025.   PrintS(" _X: Create a graphics chart instead of displaying it as text.");
  1026. #ifdef ISG
  1027.   PrintS(" _Xb: Create bitmap file instead of putting graphics on screen.");
  1028. #endif
  1029.   PrintS(" _Xb[n,c,v,a,b]: Set bitmap file output mode to X11 normal,");
  1030.   PrintS("     compacted, very compact, Ascii (bmtoa), or Windows bmp.");
  1031. #ifdef PS
  1032.   PrintS(" _Xp: Create PostScript stroke graphic instead of bitmap file.");
  1033.   PrintS(" _Xp0: Like _Xp but create complete instead of encapsulated file.");
  1034. #endif
  1035. #ifdef META
  1036.   PrintS(" _XM[0]: Create Windows metafile stroke graphic instead of bitmap.");
  1037. #endif
  1038.   PrintS(" _Xo <file>: Write output bitmap or graphic to specified file.");
  1039. #ifdef X11
  1040.   PrintS(" _XB: Display X chart on root instead of in a separate window.");
  1041. #endif
  1042.   PrintS(" _Xm: Create monochrome graphic instead of one in color.");
  1043.   PrintS(" _Xr: Create chart graphic in reversed colors (white background).");
  1044. #ifdef X11
  1045.   PrintS(" _Xw <hor> [<ver>], _ge[..]: Change the size of chart graphic.");
  1046. #else
  1047.   PrintS(" _Xw <hor> [<ver>]: Change the size of chart graphic.");
  1048. #endif
  1049.   PrintS(" _Xs <100,200,300,400>: Change the size of map or characters by %.");
  1050.   PrintS(" _Xi: Create chart graphic in slightly modified form.");
  1051.   PrintS(" _Xt: Inhibit display of chart info at bottom of graphic.");
  1052.   PrintS(" _Xu: Inhibit display of a border around graphic.");
  1053.   PrintS(" _Xl: Inhibit labeling of object points in chart graphic.");
  1054.   PrintS(" _Xj: Don't clear screen between chart updates, drawing trails.");
  1055.   PrintS(" _X1 <object>: Rotate wheel charts so object is at left edge.");
  1056.   PrintS(" _X2 <object>: Rotate wheel charts so object is at top edge.");
  1057. #ifdef X11
  1058.   PrintS(" _Xd <name>, _di[..] <name>: Open X window on specified display.");
  1059. #endif
  1060.   PrintS(" _XW: Simply create an image of the world map.");
  1061.   PrintS(" _XW0: Like _XW but do a non-rectangular Mollewide projection.");
  1062.   PrintS(" _XG [<degrees>]: Display the image of the world as a globe.");
  1063.   PrintS(" _XP: Like _XG but create the globe from a polar projection.");
  1064. #ifdef CONSTEL
  1065.   PrintS(" _XF: Display maps as constellations on the celestial sphere.");
  1066. #endif
  1067. #ifdef ISG
  1068.   PrintS(" _Xn [<mode>]: Start up chart or globe display in animation mode.");
  1069.   PrintS(" _HX: Display list of key press options for screen graphics.");
  1070. #endif
  1071. }
  1072.  
  1073.  
  1074. #ifdef WIN
  1075. /* Print a list of every command switch dealing with the Windows features */
  1076. /* that can be passed to the program, and a description of what it does.  */
  1077. /* This is part of what the -H switch prints in the MS Windows version.   */
  1078.  
  1079. void DisplaySwitchesW()
  1080. {
  1081.   PrintS(" _W <value>: Run given Windows menu command internally.");
  1082.   PrintS(" _WN <1-32000>: Set animation update delay in milliseconds.");
  1083.   PrintS(" _WM <1-48> <text>: Set Windows menu text for macro command.");
  1084. }
  1085. #endif
  1086. #endif /* GRAPH */
  1087.  
  1088.  
  1089. /* This is the dispatch procedure for all the generic table information      */
  1090. /* routines, such as those displaying the -H switch list, the list of signs, */
  1091. /* objects, default interpretations, and so on not requiring a date or time. */
  1092.  
  1093. bool FPrintTables()
  1094. {
  1095. #ifdef WIN
  1096.   if (us.fGraphics)
  1097.     return fFalse;
  1098. #endif
  1099.   if (us.fCredit) {
  1100.     DisplayCredits();
  1101.     is.fMult = fTrue;
  1102.   }
  1103.   if (us.fSwitch) {
  1104.     if (is.fMult)
  1105.       PrintL2();
  1106.     DisplaySwitches();
  1107.     is.fMult = fTrue;
  1108.   }
  1109.   if (us.fSwitchRare) {
  1110.     if (is.fMult)
  1111.       PrintL2();
  1112.     DisplaySwitchesRare();
  1113.     is.fMult = fTrue;
  1114.   }
  1115. #ifdef GRAPH
  1116.   if (us.fKeyGraph) {
  1117.     if (is.fMult)
  1118.       PrintL2();
  1119.     DisplayKeysX();
  1120.     is.fMult = fTrue;
  1121.   }
  1122. #endif
  1123.   if (us.fSign) {
  1124.     if (is.fMult)
  1125.       PrintL2();
  1126.     PrintSigns();
  1127.     is.fMult = fTrue;
  1128.   }
  1129.   if (us.fObject) {
  1130.     if (is.fMult)
  1131.       PrintL2();
  1132.     PrintObjects();
  1133.     is.fMult = fTrue;
  1134.   }
  1135.   if (us.fAspect) {
  1136.     if (is.fMult)
  1137.       PrintL2();
  1138.     PrintAspects();
  1139.     is.fMult = fTrue;
  1140.   }
  1141. #ifdef CONSTEL
  1142.   if (us.fConstel) {
  1143.     if (is.fMult)
  1144.       PrintL2();
  1145.     PrintConstellations();
  1146.     is.fMult = fTrue;
  1147.   }
  1148. #endif
  1149.   if (us.fOrbitData) {
  1150.     if (is.fMult)
  1151.       PrintL2();
  1152.     PrintOrbit();
  1153.     is.fMult = fTrue;
  1154.   }
  1155. #ifdef INTERPRET
  1156.   if (us.fMeaning) {
  1157.     if (is.fMult)
  1158.       PrintL2();
  1159.     InterpretGeneral();
  1160.     InterpretAspectGeneral();
  1161.     is.fMult = fTrue;
  1162.   }
  1163. #endif
  1164.  
  1165.   /* If we also already have enough information to generate a chart,    */
  1166.   /* then go on and do so, else exit. (So things like "-H -i file" will */
  1167.   /* work, but things like just "-H" will print and exit right away.)   */
  1168.  
  1169. #ifndef WIN
  1170.   return is.fMult && !is.fHaveInfo;
  1171. #else
  1172.   return is.fMult;
  1173. #endif
  1174. }
  1175.  
  1176. /* charts0.c */
  1177.